/**
 * Created by mac on 2017/7/3.
 */
import React, { Component } from 'react';
import {
    AppRegistry,
    StyleSheet,
    Text,
    Dimensions,
    View,
    Image,
    TextInput,
    TouchableOpacity,
} from 'react-native';

let screenW = Dimensions.get('window').width;

export default class NavigationView extends Component{

    // 构造
      constructor(props) {
        super(props);
        // 初始状态

      }


    render(){
        return(
            <View style={{width:screenW,height:44,flexDirection:'row',  opacity:this.props.opacity}}>
                <TouchableOpacity style={{padding:10}}>
                    <Image style={{width:20,height:20}} source={require('./images/icon-scan-black@2x.png')}/>
                </TouchableOpacity>
                <View style={{top:5,height:30,flex:1,backgroundColor:'lightgray',flexDirection:'row'}}>
                    <Image style={{top:6,left:8, width:16,height:16}} source={require('./images/icon-search-black@2x.png')}/>
                    <TextInput style={{flex:1,left:15,fontSize:14,}} value='好吃的零食都在这~'/>
                </View>
                <TouchableOpacity style={{padding:10}}>
                    <Image style={{width:20,height:20}} source={require('./images/icon-chat-black@2x.png')}/>
                </TouchableOpacity>
            </View>
        )
    }
}